Integrand size = 25, antiderivative size = 66 \[ \int \sqrt {a+a \sec (e+f x)} (c+d \sec (e+f x)) \, dx=\frac {2 \sqrt {a} c \arctan \left (\frac {\sqrt {a} \tan (e+f x)}{\sqrt {a+a \sec (e+f x)}}\right )}{f}+\frac {2 a d \tan (e+f x)}{f \sqrt {a+a \sec (e+f x)}} \]
2*c*arctan(a^(1/2)*tan(f*x+e)/(a+a*sec(f*x+e))^(1/2))*a^(1/2)/f+2*a*d*tan( f*x+e)/f/(a+a*sec(f*x+e))^(1/2)
Time = 0.42 (sec) , antiderivative size = 76, normalized size of antiderivative = 1.15 \[ \int \sqrt {a+a \sec (e+f x)} (c+d \sec (e+f x)) \, dx=\frac {\sec \left (\frac {1}{2} (e+f x)\right ) \sqrt {a (1+\sec (e+f x))} \left (\sqrt {2} c \arcsin \left (\sqrt {2} \sin \left (\frac {1}{2} (e+f x)\right )\right ) \sqrt {\cos (e+f x)}+2 d \sin \left (\frac {1}{2} (e+f x)\right )\right )}{f} \]
(Sec[(e + f*x)/2]*Sqrt[a*(1 + Sec[e + f*x])]*(Sqrt[2]*c*ArcSin[Sqrt[2]*Sin [(e + f*x)/2]]*Sqrt[Cos[e + f*x]] + 2*d*Sin[(e + f*x)/2]))/f
Time = 0.40 (sec) , antiderivative size = 66, normalized size of antiderivative = 1.00, number of steps used = 7, number of rules used = 6, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.240, Rules used = {3042, 4403, 3042, 4261, 216, 4279}
Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.
\(\displaystyle \int \sqrt {a \sec (e+f x)+a} (c+d \sec (e+f x)) \, dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \sqrt {a \csc \left (e+f x+\frac {\pi }{2}\right )+a} \left (c+d \csc \left (e+f x+\frac {\pi }{2}\right )\right )dx\) |
\(\Big \downarrow \) 4403 |
\(\displaystyle c \int \sqrt {\sec (e+f x) a+a}dx+d \int \sec (e+f x) \sqrt {\sec (e+f x) a+a}dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle c \int \sqrt {\csc \left (e+f x+\frac {\pi }{2}\right ) a+a}dx+d \int \csc \left (e+f x+\frac {\pi }{2}\right ) \sqrt {\csc \left (e+f x+\frac {\pi }{2}\right ) a+a}dx\) |
\(\Big \downarrow \) 4261 |
\(\displaystyle d \int \csc \left (e+f x+\frac {\pi }{2}\right ) \sqrt {\csc \left (e+f x+\frac {\pi }{2}\right ) a+a}dx-\frac {2 a c \int \frac {1}{\frac {a^2 \tan ^2(e+f x)}{\sec (e+f x) a+a}+a}d\left (-\frac {a \tan (e+f x)}{\sqrt {\sec (e+f x) a+a}}\right )}{f}\) |
\(\Big \downarrow \) 216 |
\(\displaystyle d \int \csc \left (e+f x+\frac {\pi }{2}\right ) \sqrt {\csc \left (e+f x+\frac {\pi }{2}\right ) a+a}dx+\frac {2 \sqrt {a} c \arctan \left (\frac {\sqrt {a} \tan (e+f x)}{\sqrt {a \sec (e+f x)+a}}\right )}{f}\) |
\(\Big \downarrow \) 4279 |
\(\displaystyle \frac {2 \sqrt {a} c \arctan \left (\frac {\sqrt {a} \tan (e+f x)}{\sqrt {a \sec (e+f x)+a}}\right )}{f}+\frac {2 a d \tan (e+f x)}{f \sqrt {a \sec (e+f x)+a}}\) |
(2*Sqrt[a]*c*ArcTan[(Sqrt[a]*Tan[e + f*x])/Sqrt[a + a*Sec[e + f*x]]])/f + (2*a*d*Tan[e + f*x])/(f*Sqrt[a + a*Sec[e + f*x]])
3.2.50.3.1 Defintions of rubi rules used
Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(1/(Rt[a, 2]*Rt[b, 2]))*A rcTan[Rt[b, 2]*(x/Rt[a, 2])], x] /; FreeQ[{a, b}, x] && PosQ[a/b] && (GtQ[a , 0] || GtQ[b, 0])
Int[Sqrt[csc[(c_.) + (d_.)*(x_)]*(b_.) + (a_)], x_Symbol] :> Simp[-2*(b/d) Subst[Int[1/(a + x^2), x], x, b*(Cot[c + d*x]/Sqrt[a + b*Csc[c + d*x]])], x] /; FreeQ[{a, b, c, d}, x] && EqQ[a^2 - b^2, 0]
Int[csc[(e_.) + (f_.)*(x_)]*Sqrt[csc[(e_.) + (f_.)*(x_)]*(b_.) + (a_)], x_S ymbol] :> Simp[-2*b*(Cot[e + f*x]/(f*Sqrt[a + b*Csc[e + f*x]])), x] /; Free Q[{a, b, e, f}, x] && EqQ[a^2 - b^2, 0]
Int[Sqrt[csc[(e_.) + (f_.)*(x_)]*(b_.) + (a_)]*(csc[(e_.) + (f_.)*(x_)]*(d_ .) + (c_)), x_Symbol] :> Simp[c Int[Sqrt[a + b*Csc[e + f*x]], x], x] + Si mp[d Int[Sqrt[a + b*Csc[e + f*x]]*Csc[e + f*x], x], x] /; FreeQ[{a, b, c, d, e, f}, x] && NeQ[b*c - a*d, 0] && EqQ[a^2 - b^2, 0]
Time = 4.24 (sec) , antiderivative size = 96, normalized size of antiderivative = 1.45
method | result | size |
default | \(\frac {2 \sqrt {a \left (\sec \left (f x +e \right )+1\right )}\, \left (\sqrt {-\frac {\cos \left (f x +e \right )}{\cos \left (f x +e \right )+1}}\, \operatorname {arctanh}\left (\frac {\sin \left (f x +e \right )}{\left (\cos \left (f x +e \right )+1\right ) \sqrt {-\frac {\cos \left (f x +e \right )}{\cos \left (f x +e \right )+1}}}\right ) c -d \cot \left (f x +e \right )+d \csc \left (f x +e \right )\right )}{f}\) | \(96\) |
parts | \(\frac {2 c \sqrt {a \left (\sec \left (f x +e \right )+1\right )}\, \sqrt {-\frac {\cos \left (f x +e \right )}{\cos \left (f x +e \right )+1}}\, \operatorname {arctanh}\left (\frac {\sin \left (f x +e \right )}{\left (\cos \left (f x +e \right )+1\right ) \sqrt {-\frac {\cos \left (f x +e \right )}{\cos \left (f x +e \right )+1}}}\right )}{f}-\frac {2 d \sqrt {a \left (\sec \left (f x +e \right )+1\right )}\, \left (\cot \left (f x +e \right )-\csc \left (f x +e \right )\right )}{f}\) | \(111\) |
2/f*(a*(sec(f*x+e)+1))^(1/2)*((-cos(f*x+e)/(cos(f*x+e)+1))^(1/2)*arctanh(s in(f*x+e)/(cos(f*x+e)+1)/(-cos(f*x+e)/(cos(f*x+e)+1))^(1/2))*c-d*cot(f*x+e )+d*csc(f*x+e))
Time = 0.28 (sec) , antiderivative size = 235, normalized size of antiderivative = 3.56 \[ \int \sqrt {a+a \sec (e+f x)} (c+d \sec (e+f x)) \, dx=\left [\frac {{\left (c \cos \left (f x + e\right ) + c\right )} \sqrt {-a} \log \left (\frac {2 \, a \cos \left (f x + e\right )^{2} - 2 \, \sqrt {-a} \sqrt {\frac {a \cos \left (f x + e\right ) + a}{\cos \left (f x + e\right )}} \cos \left (f x + e\right ) \sin \left (f x + e\right ) + a \cos \left (f x + e\right ) - a}{\cos \left (f x + e\right ) + 1}\right ) + 2 \, d \sqrt {\frac {a \cos \left (f x + e\right ) + a}{\cos \left (f x + e\right )}} \sin \left (f x + e\right )}{f \cos \left (f x + e\right ) + f}, -\frac {2 \, {\left ({\left (c \cos \left (f x + e\right ) + c\right )} \sqrt {a} \arctan \left (\frac {\sqrt {\frac {a \cos \left (f x + e\right ) + a}{\cos \left (f x + e\right )}} \cos \left (f x + e\right )}{\sqrt {a} \sin \left (f x + e\right )}\right ) - d \sqrt {\frac {a \cos \left (f x + e\right ) + a}{\cos \left (f x + e\right )}} \sin \left (f x + e\right )\right )}}{f \cos \left (f x + e\right ) + f}\right ] \]
[((c*cos(f*x + e) + c)*sqrt(-a)*log((2*a*cos(f*x + e)^2 - 2*sqrt(-a)*sqrt( (a*cos(f*x + e) + a)/cos(f*x + e))*cos(f*x + e)*sin(f*x + e) + a*cos(f*x + e) - a)/(cos(f*x + e) + 1)) + 2*d*sqrt((a*cos(f*x + e) + a)/cos(f*x + e)) *sin(f*x + e))/(f*cos(f*x + e) + f), -2*((c*cos(f*x + e) + c)*sqrt(a)*arct an(sqrt((a*cos(f*x + e) + a)/cos(f*x + e))*cos(f*x + e)/(sqrt(a)*sin(f*x + e))) - d*sqrt((a*cos(f*x + e) + a)/cos(f*x + e))*sin(f*x + e))/(f*cos(f*x + e) + f)]
\[ \int \sqrt {a+a \sec (e+f x)} (c+d \sec (e+f x)) \, dx=\int \sqrt {a \left (\sec {\left (e + f x \right )} + 1\right )} \left (c + d \sec {\left (e + f x \right )}\right )\, dx \]
Leaf count of result is larger than twice the leaf count of optimal. 147 vs. \(2 (58) = 116\).
Time = 0.34 (sec) , antiderivative size = 147, normalized size of antiderivative = 2.23 \[ \int \sqrt {a+a \sec (e+f x)} (c+d \sec (e+f x)) \, dx=\frac {\sqrt {a} c \arctan \left ({\left (\cos \left (2 \, f x + 2 \, e\right )^{2} + \sin \left (2 \, f x + 2 \, e\right )^{2} + 2 \, \cos \left (2 \, f x + 2 \, e\right ) + 1\right )}^{\frac {1}{4}} \sin \left (\frac {1}{2} \, \arctan \left (\sin \left (2 \, f x + 2 \, e\right ), \cos \left (2 \, f x + 2 \, e\right ) + 1\right )\right ) + \sin \left (f x + e\right ), {\left (\cos \left (2 \, f x + 2 \, e\right )^{2} + \sin \left (2 \, f x + 2 \, e\right )^{2} + 2 \, \cos \left (2 \, f x + 2 \, e\right ) + 1\right )}^{\frac {1}{4}} \cos \left (\frac {1}{2} \, \arctan \left (\sin \left (2 \, f x + 2 \, e\right ), \cos \left (2 \, f x + 2 \, e\right ) + 1\right )\right ) + \cos \left (f x + e\right )\right )}{f} \]
sqrt(a)*c*arctan2((cos(2*f*x + 2*e)^2 + sin(2*f*x + 2*e)^2 + 2*cos(2*f*x + 2*e) + 1)^(1/4)*sin(1/2*arctan2(sin(2*f*x + 2*e), cos(2*f*x + 2*e) + 1)) + sin(f*x + e), (cos(2*f*x + 2*e)^2 + sin(2*f*x + 2*e)^2 + 2*cos(2*f*x + 2 *e) + 1)^(1/4)*cos(1/2*arctan2(sin(2*f*x + 2*e), cos(2*f*x + 2*e) + 1)) + cos(f*x + e))/f
\[ \int \sqrt {a+a \sec (e+f x)} (c+d \sec (e+f x)) \, dx=\int { \sqrt {a \sec \left (f x + e\right ) + a} {\left (d \sec \left (f x + e\right ) + c\right )} \,d x } \]
Timed out. \[ \int \sqrt {a+a \sec (e+f x)} (c+d \sec (e+f x)) \, dx=\int \sqrt {a+\frac {a}{\cos \left (e+f\,x\right )}}\,\left (c+\frac {d}{\cos \left (e+f\,x\right )}\right ) \,d x \]